import sys

from awesum import *
from scenes import SceneTrack

if __name__ == "__main__":
	nArgs = len(sys.argv)
	track = sys.argv[1] if nArgs > 1 else 0
	if nArgs > 2: #DEBUG
		print "Only support for 1 or 2 cars so far"
		players = (Player.Type.LOCAL, Player.Type.LOCAL)
	else:
		players = None
	
	tg = Game()
	tg.debugMode = False
	tg.createWindow("Track Game Demo", 640, 480)
	tg.scenes.append(SceneTrack(track, players) if players else SceneTrack(track)) #DEBUG
	tg.run()